# Contributor: ayushnix <ayush@ayushnix.com>
# Contributor: TBK <alpine@jjtc.eu>
# Maintainer: TBK <alpine@jjtc.eu>
pkgname=pounce
pkgver=3.1
pkgrel=3
pkgdesc="Multi-client, TLS-only IRC bouncer"
arch="all"
url="https://git.causal.agency/pounce/"
license="GPL-3.0-or-later"
options="!check" # No test suite
makedepends="libretls-dev"
install="$pkgname.pre-install"
subpackages="$pkgname-doc $pkgname-openrc"
source="https://git.causal.agency/pounce/snapshot/pounce-$pkgver.tar.gz
		pounce.confd
		pounce.initd
		calico.confd
		calico.initd
		pounce.pre-install"

build() {
	./configure \
		--prefix=/usr \
		--mandir=/usr/share/man
	make all
}

package() {
	make DESTDIR="$pkgdir" install
	install -Dm644 "$srcdir"/pounce.confd "$pkgdir"/etc/conf.d/pounce
	install -Dm644 "$srcdir"/calico.confd "$pkgdir"/etc/conf.d/calico
	install -Dm755 "$srcdir"/pounce.initd "$pkgdir"/etc/init.d/pounce
	install -Dm755 "$srcdir"/calico.initd "$pkgdir"/etc/init.d/calico
}

sha512sums="
b2c2481e152368080e6ce9b3be2d7920eb4cac630dabb994e31170fb44977e2235c0ff30a7f08e826a329da69371a3ff2dae33831cb93b18655f98fc6569da7d  pounce-3.1.tar.gz
9f265d407b492a8cbc21455382ad0437605a2008a896f22a39c1d7606f437b5cc06b42a25f0115dc4142a1f43012a573a943ae120a124783b8f570967a7ae748  pounce.confd
c341fd11cb59766f6a41bfdc0ce69d9c771ad26291ccdd6bace5225e2ced092fc9ecf9e1f533fe7901ab3be84edd8356a523c4736beb088325f99f7105ca9ba0  pounce.initd
388f3a064705eb1e4d978e4e75e43c65342c6e3fdbc872cea0da120ea5d443598a2e5c5b574a17a2214056fdf00b3c3d103212650a958156db263d0c2830408f  calico.confd
9ad4d2b314e7ec33f353636cc57de0d609b472870cf500ddd6e222e458cbc3b93b221cc805df04b51ec41f80576e19c30b296671cea3eeab388af9a8ae6e5c5d  calico.initd
c4082bd08ee0124a10ddce240de62b8ef6e5ae85e939e856af7758ac43ef8edca3fd6e219823d6259848b59589f3db51de6d73735e4d5fcadf8c7be05d49a7bf  pounce.pre-install
"
